1. Field of the Invention
The present invention relates to an error detection and/or correction device, and more particularly to a syndrome calculation circuit in a device for detecting and/or correcting a code error using a check matrix.
2. Related Background Art
FIG. 1 is a block diagram showing a general arrangement of a syndrome calculation unit section of a digital signal code error detection and/or correction circuit. A code string is applied via a transmission line to an input terminal 10 and is written in a memory 12 on the code word unit basis. Code words X.sub.l to X.sub.n of n symbols written in the memory 12 are sequentially read and applied to multipliers 14, 16, 18 provided in m calculation circuits C.sub.O to C.sub.m for calculating syndromes S.sub.O to S.sub.m. Simultaneously with data reading from the memory 12, n coefficients at respective rows of a check matrix of m rows and n columns for calculating syndromes S.sub.O to S.sub.m are read from ROMs 20, 22, 24 and applied to the corresponding m multipliers 14, 16, 18.
The multipliers 14, 16, 18 multiply the data from the memory 12 by the corresponding coefficients from ROMs 20, 22, 24. The outputs from the multipliers 14, 16, 18 are applied to adders 26, 28, 30 for the cumulative addition by n times for each code word. Specifically, the outputs from the adders 26, 28, 30 are fed back to the addition input terminals of the adders 26, 28, 30 via delay circuits 32, 34, 36 so that the adders 26, 28, 30 cumulatively add together the outputs from each multiplier 14, 16, 18. By cumulatively adding all codes of each code word multiplied by each row of the check matrix, the syndromes S.sub.O to S.sub.m for error correction and/or detection can be obtained and stored in a syndrome memory 38. The syndromes stored in the syndrome memory 38 are used later for the error detection process.
With the conventional technique described above, syndromes for code error and/or detection are obtained through multiplication of the coefficients of n rows of the check matrix by all codes of n code length and through cumulative addition of the multiplication results. This poses a problem of a very long calculation time.